package pl.planito.entity;

import java.io.Serializable;
import javax.persistence.*;

/**
 * The primary key class for the inv_software database table.
 * 
 */
@Embeddable
public class InvSoftwarePK implements Serializable {
	//default serial version id, required for serializable classes.
	private static final long serialVersionUID = 1L;

	@Column(name="idinv_software")
	private int idinvSoftware;

	@Column(name="inventory_id_soft")
	private int inventoryIdSoft;

	@Column(name="inventory_inv_id_soft")
	private String inventoryInvIdSoft;

    public InvSoftwarePK() {
    }
	public int getIdinvSoftware() {
		return this.idinvSoftware;
	}
	public void setIdinvSoftware(int idinvSoftware) {
		this.idinvSoftware = idinvSoftware;
	}
	public int getInventoryIdSoft() {
		return this.inventoryIdSoft;
	}
	public void setInventoryIdSoft(int inventoryIdSoft) {
		this.inventoryIdSoft = inventoryIdSoft;
	}
	public String getInventoryInvIdSoft() {
		return this.inventoryInvIdSoft;
	}
	public void setInventoryInvIdSoft(String inventoryInvIdSoft) {
		this.inventoryInvIdSoft = inventoryInvIdSoft;
	}

	public boolean equals(Object other) {
		if (this == other) {
			return true;
		}
		if (!(other instanceof InvSoftwarePK)) {
			return false;
		}
		InvSoftwarePK castOther = (InvSoftwarePK)other;
		return 
			(this.idinvSoftware == castOther.idinvSoftware)
			&& (this.inventoryIdSoft == castOther.inventoryIdSoft)
			&& this.inventoryInvIdSoft.equals(castOther.inventoryInvIdSoft);

    }
    
	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.idinvSoftware;
		hash = hash * prime + this.inventoryIdSoft;
		hash = hash * prime + this.inventoryInvIdSoft.hashCode();
		
		return hash;
    }
}